package com.glink.manage.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.glink.manage.domain.ConstructionWorkSiteBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author  qiushaoshan
 * @since  2025-01-08
 */
public interface ConstructionWorkSiteMapper extends BaseMapper<ConstructionWorkSiteBean> {

    /**
     * 分页查询施工现场
     * @param constructionWorkUnitRelaBeanIPage 分页参数
     * @param constructionWorkObjId 工程ID
     * @return 施工现场信息
     */
    IPage<ConstructionWorkSiteBean> findSiteByPage(IPage<ConstructionWorkSiteBean> constructionWorkUnitRelaBeanIPage, @Param("constructionWorkObjId") String constructionWorkObjId);

    /**
     * 根据ID更新是否授权状态
     * @param workSiteIdList 施工现场ID列表
     */
    void updateIfGrantByIdIn(@Param("workSiteIdList") List<String> workSiteIdList);
}
